{# The Resend account's sending domains: status and a Check each, and Add domain, which shows the DNS records to create. Without a list, why. #} {% from "components/macros/layout.html" import card %} {% from "components/macros/table.html" import data_table %} {% from "components/macros/form.html" import action %} {% macro domain_actions(row) -%} {{ action("Check", 'hx-post="' ~ row.check_url ~ '" hx-swap="none"') }} {%- endmacro %}
{% call card("Sending domains", "Resend sends only from a verified domain") %} {% if domains.reason %}

{{ domains.reason }}

{% else %} {{ data_table([ {"key": "name", "label": "Domain", "kind": "code"}, {"key": "status", "label": "Status", "kind": "status"}, ], domains.rows, actions=domain_actions, empty="No domains yet") }}
{{ action("Add domain", hx_dialog(domains.new_url), "primary") }}
{% endif %} {% endcall %}